<template>
	<view class="this_page">
		<view class="w-706 h-400" style="margin: 0 auto;">
			<image src="../../static/img_yanglaoquanyika@2x.png" style="width: 100%;" mode="widthFix"></image>
		</view>
		<view class=" w-590" style="margin:46rpx auto 60rpx auto ;">
			<view style="width: 100%;"><text  style="line-height: 56rpx;font-weight: 600;color: #333333;font-size: 40rpx;">激活步骤</text></view>
			<view style="margin-top: 24rpx;"><text  style="line-height: 48rpx;color: #666666;font-size: 28rpx;">1. 刮开卡片背面刮刮膜查看激活码</text></view>
			<view><text  style="line-height: 48rpx;color: #666666;font-size: 28rpx;">2. 在下方输入对应激活码</text></view>
			
			<view style="width: 100%;height: 112rpx;background-color: #FFFBF6;border-radius: 12rpx;margin-top: 32rpx;display: flex;align-items: center;">
				<view><text class="w-50" style="font-size: 36rpx;line-height: 50rpx;color: #A96622;margin: auto 24rpx auto 28rpx;">JR</text></view>
				<view  style="background-color: #A96622;width: 20rpx;height: 2rpx;"></view>
				<input v-model="jhm" type="number" class="uni-input text_sm" style="font-size: 36rpx;line-height: 50rpx;color: #A96622;margin-left: 24rpx;" placeholder-style="color:#C3915F" placeholder="请输入激活码" />
				
			</view>
		</view>
		<view :style="{opacity:jhm?1:0.5}" @click="next()">
			<view class="w-480 h-92" style="margin: 60rpx auto;border-radius: 49rpx;text-align: center;
			background:linear-gradient(to right,#FE515F 0%,#FB2D19 20%,#FB2D19 80%,#FC7916 100%) ;">
			<text style="line-height: 92rpx;font-size: 32rpx;color: #FFFFFF" >下一步</text>
			</view>
		</view>
		
		<view class="w-686" style="margin: 260rpx auto 0 auto;">
			<text style="line-height: 48rpx;font-size: 24rpx;color: #666666;">注意事项：<br/>
· 权益卡上载明激活截止日期，请在激活有效期内进行激活使用；<br/>
· 请在下一步中正确填写持卡人信息，权益人为持卡人本人。</text>
		</view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				
				jhm:''
			}
		},
		methods: {
			async next(){
				
				if(this.jhm){
					const res = await this.$api.common.promotion('getCardItem', {code:this.jhm})
					if (res.code === 200) {
					  uni.$u.route('/pages/sojourn/sojourn_next?id='+res.data+'&jhm='+this.jhm)
					}
					
				}else{
					return
				}
			}
		}
	}
</script>

<style>
	.this_page{
		background: linear-gradient(to bottom,#E1B696,#FFFCF9);
		min-height: 100vh;
	}

</style>
